package com.qf.cloud.service1.feign;

import com.qf.cloud2203.domain.entity.Vote;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;

import java.util.ArrayList;
import java.util.List;

@FeignClient("SERVICE2")
public interface Service2Client {
    @RequestMapping("/service2/home")
    String home();

    @GetMapping("/service2/findAll")
    List<Vote> getVoteList();


    @PostMapping("/service2/update")
    Vote updateVote(@RequestBody Vote vote);

}

